import BasePageCtrl, { AnimType } from "./BasePageCtrl";
import TravelBeiJingFlagToastPage from "./TravelBeiJingFlagToastPage";

const { ccclass, property } = cc._decorator;

@ccclass
export default class TravelBeiJingFlagToastPageCtrl extends BasePageCtrl {
    @property(cc.Node)
    ui = null;

    onLoad() {
        super.onLoad();
        this.onUILoad();
        this._animType = AnimType.SCALE;
        this._touchControl = false;
        this._hasPeneLock = false;
        this._hasBlack = false;
        this._hasTouchLock = false;
        this._hasBlackTouch = true;
        this._init();
        this.addButtonListen();
    }

    _init() {
        this.ui.des.getComponent(cc.RichText).string = "马上就能提现10000元红包，加速闯关吧！";
        this.scheduleOnce(() => {
            this.hide();
        }, 1);
    }

    start() { }

    onUILoad() {
        this.ui = this.node.addComponent(TravelBeiJingFlagToastPage);
    }

    addButtonListen() { }

    clickClose() {
        this.hide();
    }


    static prefabUrl = "TravelBeiJingFlagToastPage";
    static className = "TravelBeiJingFlagToastPageCtrl";
}
